package Homework.cms.user;

import Homework.cms.user.Member;
import Homework.cms.user.MemberDao;

import java.util.List;

public class MemberService {
    private MemberDao dao;

    public boolean check(String telephone){
        Member member=dao.check(telephone);
        if(member!=null)
            return true;
        return false;
    }

    public Member login(String telephone, String pwd){
        Member member=dao.login(telephone,pwd);
        return member;
    }

    public boolean register(Member member){
        boolean rs=dao.register(member);
        if(rs==true)
            return true;
        return false;
    }

    public List<Member> manage(){
        List<Member> member=dao.manage();
        return member;
    }

}
